package com.bwie.vo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.bwie.pojo.TbOderInfo;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.DateFormat;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

import java.util.Date;
import java.util.List;

/**
 * @Title:
 * @BelongProjecet month0617
 * @BelongPackage com.bwie.vo
 * @Description:
 * @Copyright 研发一部
 * @Author: Mr.yan
 * @Date: 2024/6/17 11:18
 * @Version V1.0
 */
@Data
@Document(indexName = "es_order",shards = 1,replicas = 1)
public class EsOrder {
    @Id
    @Field(type = FieldType.Integer)
    private Integer id;
    @Field(type = FieldType.Text)
    private String orderNum;
    @Field(type = FieldType.Integer)
    private Integer enquiryId;
    @Field(type = FieldType.Integer)
    private Integer deliverId;
    @Field(type = FieldType.Integer)
    private Integer userId;
    @Field(type = FieldType.Integer)
    private Integer goodsId;
    @JsonFormat(shape = JsonFormat.Shape.STRING,pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Field(type = FieldType.Date,format = DateFormat.custom,pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;
    @JsonFormat(shape = JsonFormat.Shape.STRING,pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Field(type = FieldType.Date,format = DateFormat.custom,pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;
    @JsonFormat(shape = JsonFormat.Shape.STRING,pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Field(type = FieldType.Date,format = DateFormat.custom,pattern = "yyyy-MM-dd HH:mm:ss")
    private Date arriveTime;
    @Field(type = FieldType.Keyword)
    private String enquiryName;
    @Field(type = FieldType.Keyword)
    private String orderDetails;
    @Field(type = FieldType.Keyword)
    private String deliverName;
    @Field(type = FieldType.Text,analyzer = "ik_max_word")
    private String userName;
    @Field(type = FieldType.Text)
    private String goodsNum;
    @Field(type = FieldType.Text,analyzer = "ik_max_word")
    private String goodsName;
    @Field(type = FieldType.Integer)
    private Integer orderStatus;
    @Field(type = FieldType.Integer)
    private Integer goodsNumber;
    @Field(type = FieldType.Keyword)
    private String  goodsDetails;

    @Field(type = FieldType.Keyword)
    private String  orderSta;

}
